import { PageHeaderWrapper, getMenuData } from '@ant-design/pro-layout';
import React, { useState, useEffect, Component } from 'react';
import { Table, Card } from 'antd';
import { ColumnProps } from 'antd/es//table';
import ProTable, { ProColumns, ActionType } from '@ant-design/pro-table';

interface User {
  id: string;
  name: string;
  sex: string;
  createDate: string;
}

const columns: ColumnProps<User>[] = [
  {
    title: '序号',
    dataIndex: 'id',
  },
  {
    title: '姓名',
    dataIndex: 'name',
  },
  {
    title: '性别',
    dataIndex: 'sex',
  },
  {
    title: '创建时间',
    dataIndex: 'createDate',
  },
];

const data: User[] = [
  {
    id: '32423423',
    name: '李四',
    sex: '男',
    createDate: '2020-03-31',
  },
];

export default (): React.ReactNode => (
  <PageHeaderWrapper content="用户管理模块">
    <Card>
      <Table columns={columns} dataSource={data} />
    </Card>
  </PageHeaderWrapper>
);
